import request from '@/utils/request'

export function getFlashsaleList(query) {
  return request({
    url: '/promotion/flashsale/getList',
    method: 'post',
    data: query
  })
}

export function getFlashsaleDetail(id) {
  return request({
    url: '/promotion/flashsale/getDetail',
    method: 'post',
    data: id
  })
}

export function saveFlashsale(id) {
  return request({
    url: '/promotion/flashsale/save',
    method: 'post',
    data: id
  })
}

export function removeFlashsaleByID(id) {
  return request({
    url: '/promotion/flashsale/delete',
    method: 'post',
    data: id
  })
}

export function changeFlashsaleStatusByID(formdata) {
  return request({
    url: '/promotion/flashsale/change-status',
    method: 'post',
    data: formdata
  })
}

